package com.tyj.tuyijiesystem.model.juser.service.auth;


import com.tyj.tuyijiesystem.model.juser.dao.JUserDao;
import org.springframework.security.core.userdetails.UserDetails;
import org.springframework.security.core.userdetails.UserDetailsService;
import org.springframework.security.core.userdetails.UsernameNotFoundException;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
 * <p></p>
 *
 * @author lhf
 * @since 2020/6/7
 */
@Service
public class AuthServiceImpl implements UserDetailsService {
    @Resource
    private JUserDao jUserDao;

    @Override
    public UserDetails loadUserByUsername(String s) throws UsernameNotFoundException {
        return jUserDao.login(s);
    }
}
